home *** CD-ROM | disk | FTP | other *** search
/ Shareware Overload Trio 2 / Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO / dir39 / anidos.zip / ANIDOS.DOC < prev    next >
Text File  |  1993-06-29  |  49KB  |  1,284 lines

  1.  
  2.     ***************************************************************
  3.     *                                  *
  4.     *    Program Title:             DOS ANIMATOR V1.2          *
  5.     *    CompuServe Registration ID:  1046              *
  6.     *    Filename:             ANIDOS.ZIP           *
  7.     *                                  *
  8.     *    DEMONSTRATION VERSION                      *
  9.     *    Copyright (C) Matt Harvey, 1987-1993              *
  10.     *    All rights reserved                      *
  11.     *                                  *
  12.     ***************************************************************
  13.  
  14.     This is a demonstration version of DOS ANIMATOR V1.2. It has
  15.     restricted capabilities, see the appendix. To register and
  16.     receive the latest full-featured version of DOS ANIMATOR, use
  17.     the "Shareware Registration" forum on CompuServe. If you're
  18.     not on CompuServe, fill in and return the registration form
  19.     at the end of this document.
  20.  
  21.     You are free to pass copies of this software to others,
  22.     providing it is supplied in its original, unmodified form
  23.     (as file ANIDOS.ZIP), and no fee is charged for the software.
  24.  
  25.     This software was originally written to control a continuous
  26.     running software demonstration at a large software exhibition,
  27.     and has subsequently been used for automating the start-up to
  28.     tedious DOS packages, accessing bulletin boards, and software
  29.     testing.
  30.  
  31.     Recently I've used it to write a fancy Microsoft Windows "front
  32.     end" for a huge old DOS package. The Windows program creates a
  33.     DOS ANIMATOR script file, according to the operation, then
  34.     invokes the DOS application (in an invisible window). The script
  35.     file saves screen output and messages to a file, which is
  36.     processed by the Windows front-end to determine the outcome of
  37.     the action. This works fast, especially if a disk cache is used,
  38.     and saved about 10 man-years of work in re-writing the old DOS
  39.     package. Clever users of the Windows front-end can also write
  40.     their own scripts, so that they can add their own "macros" to
  41.     the Windows program.
  42.  
  43.     When it was orginally written (1987), there were no packages
  44.     readily available that could do this job. There are now several
  45.     similar products available, but they're very expensive - this
  46.     one's cheap!
  47.  
  48.                             ANIDOS
  49.  
  50.     CONTENTS
  51.     ════════
  52.                                  Page
  53.  
  54.     1.  INTRODUCTION . . . . . . . . . . . . . . . . .    1
  55.  
  56.     2.  INSTALLATION ON A HARD DISK  . . . . . . . . .    2
  57.  
  58.     3.  OPERATION  . . . . . . . . . . . . . . . . . .    3
  59.  
  60.     4.  SCRIPT FILE STATEMENTS . . . . . . . . . . . .    5
  61.         4.1   Comments . . . . . . . . . . . . . . . .    5
  62.         4.2   Key strokes  . . . . . . . . . . . . . .    5
  63.         4.3   Jump labels  . . . . . . . . . . . . . .    5
  64.         4.4   Jumps  . . . . . . . . . . . . . . . . .    6
  65.         4.5   Gosub and Return . . . . . . . . . . . .    6
  66.         4.6   Timing and delays  . . . . . . . . . . .    6
  67.         4.7   Displaying pop-up windows  . . . . . . .    7
  68.         4.8   Displaying texts . . . . . . . . . . . .    7
  69.         4.9   Interactive keyboard input . . . . . . .    8
  70.         4.10  Examining the screen . . . . . . . . . .    9
  71.         4.11  Shift, Alt, Ctrl and Lock key states . .    9
  72.         4.12  Cursor on/off  . . . . . . . . . . . . .   10
  73.         4.13  File operations  . . . . . . . . . . . .   10
  74.           4.13.1  Save     . . . . . . . . . . . . .   10
  75.           4.13.2  File     . . . . . . . . . . . . .   11
  76.           4.13.3  Unlink . . . . . . . . . . . . .   11
  77.         4.14  Quit, end script . . . . . . . . . . . .   11
  78.  
  79.     5.  SCRIPT LANGUAGE SUMMARY  . . . . . . . . . . .   12
  80.  
  81.     6.  KEY CODE TABLE . . . . . . . . . . . . . . . .   14
  82.  
  83.     7.  DISPLAY ATTRIBUTES . . . . . . . . . . . . . .   16
  84.  
  85.     8.  MEMORY REQUIREMENTS  . . . . . . . . . . . . .   16
  86.  
  87.     9.  ERROR MESSAGES . . . . . . . . . . . . . . . .   17
  88.  
  89.     10. IMPORTANT NOTES  . . . . . . . . . . . . . . .   18
  90.  
  91.     11. APPENDIX . . . . . . . . . . . . . . . . . . .   22
  92.         Terms and conditions of use
  93.         Standard disclaimer
  94.         Support
  95.         Demo version restrictions
  96.         Future enhancements
  97.     --> Registration and order form <--
  98.  
  99.                             ANIDOS - Page 1
  100.  
  101.     1.  INTRODUCTION
  102.     ════════════════
  103.  
  104.     DOS ANIMATOR is a suite of three programs which together allow
  105.     key depressions to be logged, stored in a script file, and played
  106.     back to animate any DOS program running in text mode. The script
  107.     file contains statements in a simple programing language, which
  108.     are interpreted to control the application. The script file can
  109.     be edited with any standard ASCII text editor, to simulate key
  110.     depressions, provide delays, or to display colour "pop-up" texts
  111.     anywhere on the screen. Interactive statements are also supported,
  112.     it can display a pop-up menu, then jump to any part of the script
  113.     according to the key pressed. Conditional jumps can also be made
  114.     on the contents of any part of the screen, for checking texts
  115.     displayed by the application. Screen data or any texts can be
  116.     written or appended to files.
  117.  
  118.     Primary uses are for creating demonstrations and tutorials for
  119.     existing DOS programs, for running scripts to initialize an
  120.     application, to provide interactive menu-driven "front ends"
  121.     for DOS applications (even to create Microsoft Windows front
  122.     ends), or to automate software testing.
  123.  
  124.     File ANIDOSxx.ZIP contains these files (xx is the version number,
  125.     blank for the demonstration version):
  126.  
  127.     ANIDOS.DOC    This file.
  128.     ATSR.COM      Small resident "kernel", which controls key logging
  129.               and execution of the script file.
  130.     ARUN.EXE      Loads the application program and runs the script
  131.               file, simulating key depressions, controlling the
  132.               timing, and displaying pop-up windows etc.
  133.     ALOG.EXE      Key logger, which creates the initial script file
  134.               while running the application by logging all key
  135.               depressions.
  136.     DEMO.BAT      Batch file for running the demonstration script.
  137.     DEMO.ANI      Demonstration script file, execute by running the
  138.               DEMO batch file.
  139.     DOS.COM       A dummy "do-nothing" application (which is executed
  140.               by DEMO.BAT). This allows DOS itself to be animated
  141.               without loading another copy of the COMMAND.COM
  142.               shell, thus saving memory and the "EXIT" command.
  143.               See notes in section 10.
  144.     REBOOT.COM    Utility to reboot the computer from a batch file.
  145.               Effectively removes ATSR.COM from memory.
  146.  
  147.                             ANIDOS - Page 2
  148.  
  149.     2. INSTALLATION ON A HARD DISK
  150.     ══════════════════════════════
  151.  
  152.     To install DOS ANIMATOR, create a directory named ANIDOS (or any
  153.     other suitable name), then unzip the file ANIDOSxx.ZIP into this
  154.     directory (this requires PKUNZIP). Then run the batch file named
  155.     "DEMO" (from the ANIDOS directory), which shows you some of DOS
  156.     ANIMATOR's features.
  157.  
  158.     For example:
  159.  
  160.         C:\>md anidos
  161.         C:\>cd anidos
  162.         C:\ANIDOS>pkunzip a:anidos
  163.         C:\ANIDOS>demo
  164.  
  165.  
  166.     You may also want to put the directory name into the "PATH" in
  167.     your AUTOEXEC.BAT file, so you can run DOS ANIMATOR from any
  168.     other directory (after rebooting).
  169.  
  170.                             ANIDOS - Page 3
  171.  
  172.     3. OPERATION
  173.     ════════════
  174.  
  175.     Before DOS ANIMATOR can be used, the resident program ATSR must
  176.     be loaded, with this command:
  177.  
  178.         ATSR bufsize
  179.  
  180.     "bufsize" is the buffer size in bytes (maximum 40'000). Each
  181.     logged key depression requires 2 bytes, so this gives a maximum
  182.     of up to 20'000 key depressions, excluding any space taken up
  183.     by delays and pop-up window texts etc. The default is 5'000 bytes
  184.     (space for up to 2'500 characters). The size of the buffer needed
  185.     by individual script files is determined by using ARUN with the
  186.     "/t" switch, see below. Keep this to the minimum, since it reduces
  187.     the memory available for the application. ATSR will run in high
  188.     memory, see your memory manager or DOS 5.0+ documentation.
  189.  
  190.     Next, the initial script file must be created, either using a
  191.     standard ASCII text editor, or by using the ALOG program to log
  192.     key depressions while using the application:
  193.  
  194.         ALOG scriptfile program [arguments...]
  195.  
  196.     "scriptfile" is the name of the file which will be created to
  197.     hold the logged key depressions, "program" is the name of the
  198.     application program to be run, and "arguments..." is a list
  199.     of command-line arguments required by the application. The
  200.     application program is executed, and all key depressions are
  201.     logged and saved in the script file.
  202.  
  203.     After creating a script file with ALOG, it should be examined
  204.     and edited. Delays will need to be added at certain places, and
  205.     pop-up window texts and other statements can be added. Delays
  206.     must be added which skip over any points where the application
  207.     clears the keyboard buffer to prevent type-ahead (which will eat
  208.     key depressions when they're played back), or to wait for the
  209.     application to complete a slow operation. Ensure that the delay
  210.     is long enough to be sufficient when the script is run on slow
  211.     PCs (e.g. 4.77MHz) with floppy disks.
  212.  
  213.     After editing the script file, it should be checked for valid
  214.     syntax, and the size of buffer determined, by using ARUN with
  215.     the "/t" (for test) switch:
  216.  
  217.         ARUN scriptfile /t
  218.  
  219.     Any syntax errors will be displayed, with a caret "^" pointing
  220.     to (or just after) the suspect character or value. The buffer
  221.     size can be used when loading the resident ATSR program.
  222.  
  223.                             ANIDOS - Page 4
  224.  
  225.     If testing shows no errors, the script file can then be played
  226.     back using ARUN:
  227.  
  228.         ARUN scriptfile program [arguments...]
  229.  
  230.     Playback can be aborted by pressing "SysReq". The application
  231.     can then be used as normal from then on. When aborted, the last
  232.     pop-up window displayed is cleared.
  233.  
  234.     Scripts, like most other programs, rarely run the first time.
  235.     The most common problem is caused by applications clearing the
  236.     keyboard buffer. See the IMPORTANT NOTES.
  237.  
  238.  
  239.     ARUN returns a value to DOS (which can be checked by using
  240.     ERRORLEVEL in a batch file):
  241.  
  242.         0    OK
  243.         1    ARUN command-line error
  244.         2    ATSR not loaded
  245.  
  246.         3    Can't open script file
  247.         4    Syntax error in script file
  248.         5    Read error on script file
  249.         6    Buffer too small
  250.  
  251.         7    Not enough memory to run program
  252.         8    Program not found
  253.         9    Can't run program
  254.  
  255.                             ANIDOS - Page 5
  256.  
  257.     4. SCRIPT FILE STATEMENTS
  258.     ═════════════════════════
  259.  
  260.     The script file contains key strokes, wait statements for timing,
  261.     pop-up window texts, file output, conditional statements (on key
  262.     press or screen contents), jumps, gosubs and comments. Any white
  263.     space, which is not enclosed in quotes, is ignored (spaces,
  264.     carriage returns, linefeeds and tabs). The script language is
  265.     simple and concise (to save typing), each command is introduced
  266.     by a single ASCII character in upper or lower case, for example
  267.     "j" is for Jump, "p" is for Pop-up window etc.
  268.  
  269.  
  270.     4.1  Comments
  271.     ─────────────
  272.     Comments are preceded by a ";" character. Everything after the
  273.     ";" to the end of the line is ignored. The first line of a script
  274.     file created by ALOG is a comment containing the application name
  275.     and argument list which were used when the log file was created.
  276.  
  277.  
  278.     4.2  Key strokes
  279.     ────────────────
  280.     Key strokes to be played back are entered in the following ways:
  281.  
  282.     -   as characters or strings enclosed in single or double quotes
  283.         e.g. '1'  "1"   "Hello"   '1964'  "can't"   'She said "Hi!"'
  284.  
  285.     -   as decimal ASCII codes
  286.         e.g. carriage return = 13
  287.  
  288.     -   as hexadecimal ASCII codes by preceding the hex value with "$"
  289.         e.g. carriage return = $0D, escape = $1B
  290.  
  291.     -   as scan codes in decimal or hex, for function keys and special
  292.         control keys, these are preceded by "#" if in decimal, or "#$"
  293.         if in hex
  294.         e.g. function key F1 = #59 (decimal) or #$3B (hex)
  295.  
  296.     Scan codes and ASCII key codes are listed in the key code table
  297.     in section 6. Key strokes can be removed from the keyboard buffer
  298.     with the "L" (fLush keyboard buffer) statement. The "E" (Empty)
  299.     statement waits unitl the keyboard buffer is empty.
  300.  
  301.  
  302.     4.3  Jump labels
  303.     ────────────────
  304.     Labels are destinations for the "Jump", "Gosub" or conditional
  305.     statements. Labels can be up to 20 characters long, and can
  306.     contain the alphanumeric characters A..Z and 0..9, and the
  307.     underline character '_'. Label definitions are preceded by a
  308.     colon character ':', label references do not require the colon.
  309.  
  310.         :a_label        ; Label definitions are preceded by a colon
  311.                 ; (no space allowed between colon and label)
  312.         :ThisIsALongLabel
  313.         :1234        ; Numbers can also be used
  314.         j a_label        ; Label reference - jump to label "a_label"
  315.  
  316.                             ANIDOS - Page 6
  317.  
  318.     4.4  Jumps
  319.     ──────────
  320.     The "J" (Jump) statement jumps to a label and continues executing
  321.     the script from there.
  322.  
  323.         J label        ; ":label" is the destination, see 4.3
  324.  
  325.  
  326.     4.5  Gosub and Return
  327.     ─────────────────────
  328.     The "G" (Gosub) statement calls a labelled subroutine, and the
  329.     "R" (Return) statement returns from the subroutine to continue
  330.     execution from the statement after the gosub. Subroutine calls
  331.     can be nested up to 8 deep, e.g. subroutines can contain "Gosub"
  332.     statements. If nesting is deeper than 8, the gosub call is
  333.     ignored.
  334.  
  335.         ...
  336.         G MySub        ; call the subroutine
  337.         ...         ; on return, execution continues from here
  338.         Q            ; end of script
  339.  
  340.         :MySub        ; start of subroutine
  341.         ...         ; subroutine body, any statements
  342.         R            ; return from subroutine
  343.  
  344.  
  345.     4.6  Timing and delays
  346.     ──────────────────────
  347.     There are two timing statements:
  348.  
  349.     -   The delay between key depressions on playback can be set with
  350.         a "Dn" (Delay) statement, where "n" is the number of real-
  351.         time clock ticks to delay. The delay can be changed at any
  352.         time, and remains in effect until another delay statement is
  353.         processed, e.g. D18 = one second.
  354.         The default is 0.5 second. D1 is about 18 characters per
  355.         second. Use D0 for no delays between characters, see notes
  356.         in section 10.
  357.  
  358.     -   Waits can be entered with the "Wn" (Wait) statement, where
  359.         "n" is the number of real-time clock ticks to delay. Waits
  360.         are typically used to pause while the application completes
  361.         a long operation, to skip over a point where the application
  362.         clears the keyboard buffer, or to pause to give time for a
  363.         pop-up text window to be read.
  364.         e.g. W180 = ten second delay
  365.  
  366.     The real-time clock "ticks" every 55 milliseconds. There are 18.2
  367.     ticks per second, so "w18" waits for about one second.
  368.  
  369.                             ANIDOS - Page 7
  370.  
  371.     4.7  Displaying pop-up windows
  372.     ──────────────────────────────
  373.     Pop-up windows are introduced with the "P" (Pop-up) statement:
  374.  
  375.         P attr column line
  376.         text line(s)...        ; each on a fresh line
  377.         .                ; "." ends the statement
  378.  
  379.         attr    The display attribute as a decimal or hex
  380.             number (0-255), e.g. 62 or $3E = yellow text on
  381.             a cyan background, see the table below. Ignored
  382.             if mono screen (but must be present anyway).
  383.         column    The column number (0..79) of the top right-hand
  384.             corner of the window in decimal.
  385.         line    The line number (0..24) of the top right-hand
  386.             corner of the window in decimal.
  387.         .        Ends the "P" statement, must be on a fresh line
  388.  
  389.     A box is automatically drawn around the window.
  390.  
  391.     The last pop-up window is cleared with a "C" (Clear) statement.
  392.     Note that if more than one pop-up window is displayed on the
  393.     same screen, only the last window can be cleared.
  394.  
  395.     For example:
  396.  
  397.         p $3e 10 3                ; display a window
  398.         This is a pop-up window
  399.         displayed on line 3, column
  400.         10, with yellow text on a
  401.         cyan background.
  402.         .                    ; end of window
  403.         w180 c                ; wait 10 seconds, then
  404.                         ; clear the window
  405.  
  406.     This displays the box:
  407.  
  408.         ╔═════════════════════════════╗
  409.         ║ This is a pop-up window      ║
  410.         ║ displayed on line 3, column ║
  411.         ║ 10, with yellow text on a   ║
  412.         ║ cyan background.          ║
  413.         ╚═════════════════════════════╝
  414.  
  415.  
  416.     4.8  Displaying texts
  417.     ─────────────────────
  418.     Texts, without a box drawn around them, are displayed with
  419.     the "T" (Text) statement, which is similar to the pop-up window
  420.     statement described above. These are also cleared with the
  421.     "C" statement.
  422.  
  423.         T attr column line
  424.         text....            ; one or more lines of text
  425.         .                ; "." ends the statement
  426.  
  427.     e.g.    T 15 5 13
  428.         <-- Command line
  429.         .
  430.  
  431.                             ANIDOS - Page 8
  432.  
  433.     4.9  Interactive keyboard input (not in demonstration version)
  434.     ──────────────────────────────────────────────────────────────
  435.     DOS ANIMATOR can pause and wait for the user to press a key, and
  436.     can then jump to a label according to which key is pressed, with
  437.     the "K" (on Key) statement:
  438.  
  439.         K
  440.         key label ...   ; key code and label to jump to if key pressed
  441.         .            ; "." ends the statement
  442.  
  443.     The key can be an ASCII character enclosed in single or double
  444.     quotes (not case sensitive) e.g. "k"; a decimal or hex key code
  445.     e.g. 12, $34; or a decimal or hex scan code e.g. #23, #$45. Each
  446.     key and associated label should be on a separate line.
  447.  
  448.     To accept any key, leave out the key and label lines, use only:
  449.  
  450.         K .         ; waits for any key to be pressed
  451.  
  452.  
  453.     For example, this script implements a (very) basic DOS menu. If
  454.     this was in a file called "DOSMENU", it would be executed with
  455.     the command: "ARUN DOSMENU DOS".
  456.  
  457.         :loop
  458.         d0
  459.         t 62 20 3
  460.          ╓── VERY BASIC DOS MENU ──┐ 
  461.          ║       D   Directory       │
  462.          ║       V   Version           │
  463.          ║       Q   Quit           │
  464.          ║       F1  Help           │
  465.          ║     Press D, V, Q or F1.  │
  466.          ╚═════════════════════════╛
  467.         .
  468.         k
  469.         'd' dir             ; if 'd' or 'D' pressed, jump to "dir"
  470.         'v' ver             ; if 'v' or 'V' pressed, jump to "ver"
  471.         'q' quit            ; if 'q' or 'Q' pressed, jump to "quit"
  472.         #$3B help        ; "F1" = Help
  473.         .            ; . = end of key/label list
  474.         :dir     c 'dir /w' 13 j done   ; directory
  475.         :ver     c 'ver' 13 j done      ; version
  476.         :quit    'cls' 13 q             ; quit, end the script
  477.         :help
  478.         p $1e 15 9
  479.         A pop-up help window.
  480.         Press any key to continue.
  481.         .
  482.         k .         ; input any key
  483.         c j loop        ; clear pop-up help window, continue
  484.         :done
  485.         0            ; NUL, causes DOS to wait until complete
  486.         j loop        ; re-display the menu
  487.  
  488.                             ANIDOS - Page 9
  489.  
  490.     4.10  Examining the screen (not in demonstration version)
  491.     ─────────────────────────────────────────────────────────
  492.     The "X" (eXamine) statement allows any part of the screen to be
  493.     examined and compared with one or more strings. A jump is made
  494.     according to which string matches the data on the screen at the
  495.     given location. The comparison IS case sensitive. If no string
  496.     matches, script execution "falls through" and continues from the
  497.     next statement. Up to 80 strings can be compared in one statement.
  498.  
  499.     This feature should be used to determine if certain actions were
  500.     successfully completed, such as making connection via a modem or
  501.     opening a file etc. It is normally used to check for the presence
  502.     of error messages.
  503.  
  504.         X column line        ; starting column and line
  505.         "string1" label1        ; first string to compare
  506.         "string2" label2 ...    ; other strings (up to 80 maximum)
  507.         .                ; "." ends the list
  508.  
  509.     For example:
  510.  
  511.         X 1 23            ; examine line 23 column 1
  512.         "ERROR" Error           ; if it contains the word "ERROR"
  513.                     ; then jump to label "Error"
  514.         "     " NoError         ; else jump to label "NoError"
  515.         .                ; else continue
  516.  
  517.  
  518.     4.11  Shift, Alt, Ctrl and Lock key states
  519.     ──────────────────────────────────────────
  520.     The states of the shift, control, alt, num lock, scroll lock,
  521.     caps lock and insert keys are controlled by "+k" and "-k"
  522.     statements, where "k" is a character which determines the key.
  523.  
  524.     e.g. +a #30 -a    = Alt key down, Alt+A, Alt key up.
  525.          +n     = Num Lock on
  526.  
  527.     ┌──────┬─────┬──────────────────┬─────┬─────┬──────────────┐
  528.     │ DOWN │ UP  │ SHIFT KEYS    │  ON │ OFF │ TOGGLE KEYS  │
  529.     ├──────┼─────┼──────────────────┼─────┼─────┼──────────────┤
  530.     │  +R  │ -R  │ Right Shift key    │  +S │ -S  │ Scroll Lock  │
  531.     │  +L  │ -L  │ Left Shift key    │  +N │ -N  │ Num Lock       │
  532.     │  +C  │ -C  │ Ctrl key     │  +K │ -K  │ Caps Lock    │
  533.     │  +X  │ -X  │ Right Ctrl key    │  +I │ -I  │ Insert       │
  534.     │  +A  │ -A  │ Alt key        │     │     │           │
  535.     │  +Z  │ -Z  │ Right Alt key    │     │     │           │
  536.     └──────┴─────┴──────────────────┴─────┴─────┴──────────────┘
  537.  
  538.     NOTE: These affect only the keyboard status flags, the correct
  539.           ASCII codes or scan codes must be used to represent Ctrl
  540.           and Alt characters. For example, don't use "+c 'c' -c"
  541.           for Ctrl+C, instead use 3 (the ASCII code for Ctrl+C is
  542.           3), "+c 3 -c" is also valid and may be required by some
  543.           applications.
  544.  
  545.                             ANIDOS - Page 10
  546.  
  547.     4.12  Cursor on/off
  548.     ──────────────────
  549.     The cursor can be turned off with the "O" (Off) command, and
  550.     back on again with the "N" (oN) command. The cursor must be
  551.     turned off *before* it can be turned on again, because this
  552.     saves the original cursor shape, which is restored when it is
  553.     subsequently turned on.
  554.  
  555.  
  556.     4.13  File commands (not in demonstration version)
  557.     ──────────────────────────────────────────────────
  558.     There are three commands for accessing files. "Save" saves
  559.     screen data to a file, "File" writes a given text to a file,
  560.     and "Unlink" deletes a file. Files can be used as a simple
  561.     communication method between an animated DOS program, and a
  562.     "front-end" Microsoft Windows program.
  563.  
  564.  
  565.     4.13.1    Save
  566.     ────────────
  567.     The "S" (Save) statement saves a defined section of the screen
  568.     to a file. It can either create a new file, or append the text
  569.     to an existing file. The top right-hand corner, and bottom left-
  570.     hand corner of the area to be saved must be given.
  571.  
  572.     This feature is very useful for saving error messages or data
  573.     that is displayed by an application which cannot save this
  574.     information in a file, or for saving screens so that they can be
  575.     compared with the correct screens for automated software testing.
  576.     It is also useful for storing data which can be processed by
  577.     another program, for example by a Microsoft Windows "front-end"
  578.     for an old DOS program, which is being controlled by DOS ANIMATOR.
  579.  
  580.     Format:
  581.  
  582.         S top_col top_line bot_col bot_line filename [A]
  583.  
  584.         top_col top_line    Top corner of block to be saved.
  585.         bot_col bot_line    Bottom corner of block to be saved.
  586.         filename        Name of file to save the text in, may be
  587.                 a complete drive/path name.
  588.         A            Optional "Append" flag. If present then
  589.                 the file is assumed to exist, and the
  590.                 text is appended to the end of the file.
  591.                 If not present, then the file is created
  592.                 (any existing file is deleted).
  593.  
  594.     "Save" examples:
  595.  
  596.         s 0 0 79 24 screen.txt    ; Saves the entire screen to
  597.                     ; file "screen.txt" in the
  598.                     ; current directory.
  599.         s 10 3 20 5 \test\1.txt a    ; Appends lines 3..5, columns
  600.                     ; 10..20 to the end of file
  601.                     ; "\test\1.txt".
  602.  
  603.                             ANIDOS - Page 11
  604.  
  605.     4.13.2    File
  606.     ────────────
  607.     The "F" (File) statement writes or appends a given text to
  608.     a given file. This can be useful in logging the progress of an
  609.     application. For example, the "X" (eXamine) statement can check
  610.     the screen for certain messages, and can write a progress report
  611.     to a file.
  612.  
  613.     Format:
  614.  
  615.         F "text" filename [A]
  616.  
  617.         text    Text to be written to the file.
  618.         filename    Name of the file to save the text in.
  619.         A            Optional "Append" flag. If present then
  620.                 the file is assumed to exist, and the
  621.                 text is appended to the end of the file.
  622.                 If not present, then the file is created
  623.                 (any existing file with the same name is
  624.                 deleted).
  625.  
  626.     Example:
  627.  
  628.         F "An error occurred" errors.txt
  629.                 ; Writes the string "An error occurred"
  630.                 ; to file "errors.txt" in the current
  631.                 ; directory
  632.  
  633.  
  634.     4.13.3    Unlink
  635.     ──────────────
  636.     The "U" (Unlink) statement deletes a file.
  637.  
  638.     Examples:
  639.  
  640.         U c:\test\fred.txt        ; Deletes file "c:\test\fred.txt"
  641.  
  642.  
  643.     4.14  Quit, end the script
  644.     ──────────────────────────
  645.     The "Q" (Quit) statement can be placed anywhere in the script,
  646.     and terminates script execution. The application can be used as
  647.     normal from this point.
  648.  
  649.     Example:
  650.  
  651.         :EndScript q        ; Jump to EndScript to quit script
  652.  
  653.                             ANIDOS - Page 12
  654.  
  655.     5. SCRIPT LANGUAGE SUMMARY
  656.     ══════════════════════════
  657.  
  658.     "ASCII keys" or 'ASCII keys'    ; E.g. "CAN'T" or '"HELLO"'
  659.  
  660.     ; comment          ; Ignored, allowed anywhere in script file
  661.  
  662.     P attr column line    ; Display pop-up window
  663.     window text...
  664.     .              ; "." ends the statement
  665.  
  666.     T attr column line    ; Display text
  667.     text lines...
  668.     .              ; "." ends the statement
  669.  
  670.     C              ; Close pop-up or text window
  671.  
  672.     Dn              ; Set default delay between keys
  673.                   ;   to "n" ticks (D0 = no delay)
  674.                   ;   e.g. D10 = 10 x 55mS = 0.55S
  675.     Wn              ; Wait "n" ticks
  676.                   ;   e.g. W180 = 180 x 55mS = 10S
  677.     #n              ; Decimal scan code
  678.                   ;   e.g. #81 = PgDn
  679.     #$n              ; Hex scan code
  680.                   ;   e.g. #$51 = PgDn
  681.     n              ; Decimal ASCII character
  682.                   ;   e.g. 13 = carriage return
  683.     $n              ; Hex ASCII character
  684.                   ;   e.g. $0D = carriage return
  685.     :label              ; Label definition
  686.     J label           ; Jump to "label"
  687.  
  688.     G label           ; Gosub, call subroutine "label"
  689.     R              ; Return, return from subroutine
  690.  
  691.     K              ; On Key
  692.     key1 label1          ;   if "key", jump to "label"
  693.     key2 label2....       ;   can contain many keys...
  694.     .              ;   "." ends the statement
  695.  
  696.     X column line          ; Examine the screen, if it
  697.     "string1" label1      ;   contains "string" jump to "label",
  698.     "string2" label2 ...  ;   can compare up to 80 strings,
  699.     .              ;   "." ends the statement
  700.  
  701.     E              ; Wait until keyboard buffer is empty
  702.     L              ; fLushes (clears) the keyboard buffer
  703.     O              ; Turn Off the cursor
  704.     N              ; Turn oN the cursor
  705.  
  706.                   ; Save screen data to a file
  707.     S top_col top_lin bot_col bot_lin filename [A]
  708.     F "text" [A]          ; FIle, write text to a file
  709.     U              ; Unlink (delete) a file
  710.  
  711.     Q              ; Quit, end script execution
  712.  
  713.                             ANIDOS - Page 13
  714.  
  715.     Shift keys (+ down, - up):      Toggle keys (+ on, - off):
  716.  
  717.     +R -R    ; Right Shift key      +S -S     ; Scroll Lock
  718.     +L -L    ; Left Shift key      +N -N     ; Num Lock
  719.     +C -C    ; Ctrl key          +K -K     ; Caps Lock
  720.     +X -X    ; Right Ctrl key      +I -I     ; Insert
  721.     +A -A    ; Alt key
  722.     +Z -Z    ; Right Alt key
  723.  
  724.                             ANIDOS - Page 14
  725.  
  726.     6. KEY CODE TABLE
  727.     ═════════════════
  728.  
  729.       ┌──────┬────────┬────────────┬────────────┬────────────┬────────────┐
  730.       │      │    SCAN  │   ASCII    │   SHIFT    │    CTRL    │      ALT      │
  731.       │      │    CODE  │        │        │         │          │
  732.       │ Key  │ Dec Hex│ Dec Hex Chr│ Dec Hex Chr│ Dec Hex Chr│ Dec Hex Chr│
  733.       ╞══════╪════════╪════════════╪════════════╪════════════╪════════════╡
  734.       │ ESC  │ 1   01 │ 27  1B    ESC│ 27  1B  ESC│ 27  1B     │          │
  735.       │ 1  ! │ 2   02 │ 49  31     1 │ 33  21   ! │         │ 120 78  NUL│
  736.       │ 2  @ │ 3   03 │ 50  32     2 │ 64  40   @ │ 3   03  NUL│ 121 79  NUL│
  737.       │ 3  # │ 4   04 │ 51  33     3 │ 35  23   # │         │ 122 7A  NUL│
  738.       │ 4  $ │ 5   05 │ 52  34     4 │ 36  24   $ │         │ 123 7B  NUL│
  739.       │ 5  % │ 6   06 │ 53  35     5 │ 37  25   % │         │ 124 7C  NUL│
  740.       │ 6  ^ │ 7   07 │ 54  36     6 │ 94  5E   ^ │ 30  1E     │ 125 7D  NUL│
  741.       │ 7  & │ 8   08 │ 55  37     7 │ 38  26   & │         │ 126 7E  NUL│
  742.       │ 8  * │ 9   09 │ 56  38     8 │ 42  2A   * │         │ 127 7F  NUL│
  743.       │ 9  ( │ 10  0A │ 57  39     9 │ 40  28   ( │         │ 128 80  NUL│
  744.       │ 0  ) │ 11  0B │ 48  30     0 │ 41  29   ) │         │ 129 81  NUL│
  745.       │ -  _ │ 12  0C │ 45  2D     - │ 95  5F   _ │ 31  1F     │ 130 82  NUL│
  746.       │ =  + │ 13  0D │ 61  3D     = │ 43  2B   + │         │ 131 83  NUL│
  747.       │ BKSP │ 14  0E │ 8   08       │ 8     08    │ 127 7F     │          │
  748.       │ TAB  │ 15  0F │ 9   09       │ 15  0F  NUL│         │          │
  749.       │ Q    │ 16  10 │ 113 71     q │ 81  51   Q │ 17  11     │ 16  10  NUL│
  750.       │ W    │ 17  11 │ 119 77     w │ 87  57   W │ 23  17     │ 17  11  NUL│
  751.       │ E    │ 18  12 │ 101 65     e │ 69  45   E │ 5   05     │ 18  12  NUL│
  752.       │ R    │ 19  13 │ 114 72     r │ 82  52   R │ 18  12     │ 19  13  NUL│
  753.       │ T    │ 20  14 │ 116 74     t │ 84  54   T │ 20  14     │ 20  14  NUL│
  754.       │ Y    │ 21  15 │ 121 79     y │ 89  59   Y │ 25  19     │ 21  15  NUL│
  755.       │ U    │ 22  16 │ 117 75     u │ 85  55   U │ 21  15     │ 22  16  NUL│
  756.       │ I    │ 23  17 │ 105 69     i │ 73  49   I │ 9   09     │ 23  17  NUL│
  757.       │ O    │ 24  18 │ 111 6F     o │ 79  4F   O │ 15  0F     │ 24  18  NUL│
  758.       │ P    │ 25  19 │ 112 70     p │ 80  50   P │ 16  10     │ 25  19  NUL│
  759.       │ [  { │ 26  1A │ 91  5B     [ │ 123 7B   { │ 27  1B  ESC│          │
  760.       │ ]  } │ 27  1B │ 93  5D     ] │ 125 7D   } │ 29  1D     │          │
  761.       │ Enter│ 28  1C │ 13  0D    CR │ 13  0D  CR │ 10  0A  LF │          │
  762.       │ Ctrl │ 29  1D │        │        │         │          │
  763.       │ A    │ 30  1E │ 97  61     a │ 65  41   A │ 1   01     │ 30  1E  NUL│
  764.       │ S    │ 31  1F │ 115 73     s │ 83  53   S │ 19  13     │ 31  1F  NUL│
  765.       │ D    │ 32  20 │ 100 64     d │ 68  44   D │ 4   04     │ 32  20  NUL│
  766.       │ F    │ 33  21 │ 102 66     f │ 70  46   F │ 6   06     │ 33  21  NUL│
  767.       │ G    │ 34  22 │ 103 67     g │ 71  47   G │ 7   07     │ 34  22  NUL│
  768.       │ H    │ 35  23 │ 104 68     h │ 72  48   H │ 8   08     │ 35  23  NUL│
  769.       │ J    │ 36  24 │ 106 6A     i │ 74  4A   I │ 10  0A     │ 36  24  NUL│
  770.       │ K    │ 37  25 │ 107 6B     j │ 75  4B   J │ 11  0B     │ 37  25  NUL│
  771.       │ L    │ 38  26 │ 108 6C     k │ 76  4C   K │ 12  0C     │ 38  26  NUL│
  772.       │ ;  : │ 39  27 │ 59  3B     ; │ 58  3A   : │         │          │
  773.       │ '  " │ 40  28 │ 39  27   ' │ 34  22   " │            │            │
  774.       │ `  ~ │ 41  29 │ 96  60     ` │ 126 7E   ~ │         │          │
  775.       └──────┴────────┴────────────┴────────────┴────────────┴────────────┘
  776.  
  777.     NOTE: The Dec and Hex numbers for keys which have NUL in the
  778.           "Chr" column are SCAN CODES. Scan codes are put into the
  779.           script file with #nn (decimal) or #$nn (hex).
  780.  
  781.                             ANIDOS - Page 15
  782.  
  783.  
  784.       ┌──────┬────────┬────────────┬────────────┬────────────┬────────────┐
  785.       │      │    SCAN  │   ASCII    │   SHIFT    │    CTRL    │      ALT      │
  786.       │      │    CODE  │        │        │         │          │
  787.       │ Key  │ Dec Hex│ Dec Hex Chr│ Dec Hex Chr│ Dec Hex Chr│ Dec Hex Chr│
  788.       ╞══════╪════════╪════════════╪════════════╪════════════╪════════════╡
  789.       │LShift│ 42  2A │        │        │         │          │
  790.       │ \  | │ 43  2B │ 92  5C     \ │ 124 7C   | │ 28  1C     │          │
  791.       │ Z    │ 44  2C │ 122 7A     z │ 90  5A   Z │ 26  1A     │ 44  2C  NUL│
  792.       │ X    │ 45  2D │ 120 78     x │ 88  58   X │ 24  18     │ 45  2D  NUL│
  793.       │ C    │ 46  2E │ 99  63     c │ 67  43   C │ 3   03     │ 46  2E  NUL│
  794.       │ V    │ 47  2F │ 118 76     v │ 86  56   V │ 22  16     │ 47  2F  NUL│
  795.       │ B    │ 48  30 │ 98  62     b │ 66  42   B │ 2   02     │ 48  30  NUL│
  796.       │ N    │ 49  31 │ 110 6E     n │ 78  4E   N │ 14  0E     │ 49  31  NUL│
  797.       │ M    │ 50  32 │ 109 6D     m │ 77  4D   M │ 13  0D     │ 50  32  NUL│
  798.       │ ,  < │ 51  33 │ 44  2C     , │ 60  3C   < │         │          │
  799.       │ .  > │ 52  34 │ 46  2E     . │ 62  3E   > │         │          │
  800.       │ /  ? │ 53  35 │ 47  2F     / │ 63  3F   ? │         │          │
  801.       │RShift│ 54  36 │        │        │         │          │
  802.       │*PrtSc│ 55  37 │ 42  2A     * │        INT5│         │          │
  803.       │ Alt  │ 56  38 │        │        │         │          │
  804.       │ Space│ 57  39 │ 32  20       │ 32  20    │ 32  20     │ 32  20      │
  805.       │ Caps │ 58  3A │        │        │         │          │
  806.       │  F1  │ 59  3B │ 59  3B    NUL│ 84  54  NUL│ 94  5E  NUL│ 104     NUL│
  807.       │  F2  │ 60  3C │ 60  3C    NUL│ 85  55  NUL│ 95  5F  NUL│ 105     NUL│
  808.       │  F3  │ 61  3D │ 61  3D    NUL│ 86  56  NUL│ 96  60  NUL│ 106     NUL│
  809.       │  F4  │ 62  3E │ 62  3E    NUL│ 87  57  NUL│ 97  61  NUL│ 107     NUL│
  810.       │  F5  │ 63  3F │ 63  3F    NUL│ 88  58  NUL│ 98  62  NUL│ 108     NUL│
  811.       │  F6  │ 64  40 │ 64  40    NUL│ 89  59  NUL│ 99  63  NUL│ 109     NUL│
  812.       │  F7  │ 65  41 │ 65  41    NUL│ 90  5A  NUL│ 100 64  NUL│ 110     NUL│
  813.       │  F8  │ 66  42 │ 66  42    NUL│ 91  5B  NUL│ 101 65  NUL│ 111     NUL│
  814.       │  F9  │ 67  43 │ 67  43    NUL│ 92  5C  NUL│ 102 66  NUL│ 112     NUL│
  815.       │  F10 │ 68  44 │ 68  44    NUL│ 93  5D  NUL│ 103 67  NUL│ 113     NUL│
  816.       │ Num  │ 69  45 │        │        │         │          │
  817.       │Scroll│ 70  46 │        │        │         │          │
  818.       │ Home │ 71  47 │ 71  47    NUL│ 55  37   7 │ 119 77  NUL│          │
  819.       │  Up  │ 72  48 │ 72  48    NUL│ 56  38   8 │         │          │
  820.       │ PgUp │ 73  49 │ 73  49    NUL│ 57  39   9 │ 132 84  NUL│          │
  821.       │Grey -│ 74  4A │ 45  2D     - │ 45  2D   - │         │          │
  822.       │ Left │ 75  4B │ 75  4B    NUL│ 52  34   4 │ 115 73  NUL│          │
  823.       │Center│ 76  4C │        │ 53  35   5 │         │          │
  824.       │ Right│ 77  4D │ 77  4D    NUL│ 54  36   6 │ 116 74  NUL│          │
  825.       │Grey +│ 78  4E │ 43  2B     + │ 43  2B   + │         │          │
  826.       │ End  │ 79  4F │ 79  4F    NUL│ 49  31   1 │ 117 75  NUL│          │
  827.       │ Down │ 80  50 │ 80  50    NUL│ 50  32   2 │         │          │
  828.       │ PgDn │ 81  51 │ 81  51    NUL│ 51  33   3 │ 118 76  NUL│          │
  829.       │ Ins  │ 82  52 │ 82  52    NUL│ 48  30   0 │         │          │
  830.       │ Del  │ 83  53 │ 83  53    NUL│ 46  2E   . │         │          │
  831.       └──────┴────────┴────────────┴────────────┴────────────┴────────────┘
  832.  
  833.     NOTE: The Dec and Hex numbers for keys which have NUL in the
  834.           "Chr" column are SCAN CODES. Scan codes are put into the
  835.           script file with #nn (decimal) or #$nn (hex).
  836.  
  837.                             ANIDOS - Page 16
  838.  
  839.     7. DISPLAY ATTRIBUTES
  840.     ═════════════════════
  841.  
  842.     The attribute is a one-byte value, where the most significant
  843.     3 bits (6..4) define the background colour, and the least
  844.     significant 4 bits (3..0) define the foreground (text) colour,
  845.     bit 7 controls blinking. These are the values in hex:
  846.  
  847.         Background colours        Foreground colours
  848.         (1st hex digit)        (2nd hex digit)
  849.         ──────────────────        ──────────────────
  850.         Black    0        Black        0
  851.         Blue    1        Blue        1
  852.         Green    2        Green        2
  853.         Cyan    3        Cyan        3
  854.         Red     4        Red        4
  855.         Magenta    5        Magenta     5
  856.         Brown    6        Brown        6
  857.         White    7        White        7
  858.                     Dark grey    8
  859.                     Light blue    9
  860.                     Light green    A
  861.                     Light cyan    B
  862.                     Light red    C
  863.                     Light magenta    D
  864.                     Yellow        E
  865.                     White        F
  866.  
  867.     For example, a cyan background with yellow foreground text
  868.     is $3E hex (62 decimal).
  869.  
  870.     To make the foreground blink, add 80 hex (128 decimal) to the
  871.     value, e.g. $0F = white foreground, black background
  872.             $8F = blinking white foreground, black background
  873.  
  874.  
  875.     8. MEMORY REQUIREMENTS
  876.     ══════════════════════
  877.  
  878.     The resident kernel (ATSR) uses about 7000 bytes + buffer size.
  879.  
  880.     The buffer size is defined when ATSR is loaded, using the command:
  881.     ATSR bufsize  (not demonstration version).
  882.  
  883.     ALOG remains resident in memory while running the application to
  884.     log key depressions. This uses just over 20K bytes.
  885.  
  886.     ARUN is *not* resident in memory when the application runs, and
  887.     does not reduce the amount of memory available to the application.
  888.  
  889.     If the application gives an "out of memory" error:
  890.  
  891.     -   Ensure that ATSR's buffer is not larger than necessary.
  892.         Use the buffer size shown by using the command:
  893.         ARUN scriptfile /T
  894.  
  895.     -   Remove any unnecessary memory-resident programs, TSRs, and
  896.         device drivers, such as RAM disks, disk caches, DOS shells
  897.         etc.
  898.  
  899.                             ANIDOS - Page 17
  900.  
  901.     9. ERROR MESSAGES
  902.     ═════════════════
  903.  
  904.     <n> syntax error(s) in script file: <filename>
  905.  
  906.         ARUN displays all script file lines which contain syntax
  907.         errors. The line number of the invalid line is displayed,
  908.         followed by the line itself, with a caret ^ pointing to
  909.         (or just after) the invalid character. A ">" character
  910.         is shown if the error location is beyond column 80. If any
  911.         errors are found, the script file will not be run.
  912.  
  913.     ATSR not loaded
  914.  
  915.         Run program ATSR.COM to install the memory resident section
  916.         of the program before running ALOG or ARUN.
  917.  
  918.     Can't open file: <filename>
  919.  
  920.         a)    Trying to read the script file - the file doesn't exist
  921.         in the current or given directory.
  922.         b)    Trying to write the script file - the disk is full or
  923.         not ready.
  924.         c)    Trying to run the application - the application is not
  925.         in the current directory, or is not in the PATH, or is
  926.         a batch file (.BAT). Batch files cannot be run directly
  927.         by ARUN, see notes in section 10.
  928.  
  929.     Read error on file: <filename>
  930.  
  931.         Corrupted application or script file.
  932.  
  933.     Exec file format error: <filename>
  934.  
  935.         The file is not an ".EXE" or ".COM" format file.
  936.  
  937.     Not enough memory to run program: <filename>
  938.  
  939.         More memory can be obtained by removing other memory-resident
  940.         programs such as disk caches, RAM disks, DOS shells etc. The
  941.         ATSR buffer size can also be reduced to a minimum (use the
  942.         buffer size shown by running ARUN with the "/t" switch).
  943.  
  944.     Buffer size too small
  945.  
  946.         The size of the buffer set when ATSR was loaded is too
  947.         small. Reboot the machine with Ctrl+Alt+Del, then execute
  948.         ATSR bufsize, where "bufsize" is the buffer size required
  949.         by the script you want to run.
  950.  
  951.     <line>: Out of label space
  952.  
  953.         DOS ANIMATOR allows a maximum of 100 label definitions, and
  954.         200 label references in a single script file.
  955.  
  956.     <line>: Multi-defined label: <label>
  957.  
  958.         The <label> is defined more than once in the script file.
  959.  
  960.     Undefined label: <label>
  961.  
  962.         The label has been referenced but is not defined.
  963.  
  964.                             ANIDOS - Page 18
  965.  
  966.     10. IMPORTANT NOTES
  967.     ═══════════════════
  968.  
  969.     OPERATING SYSTEMS AND MICROSOFT WINDOWS:
  970.  
  971.     DOS ANIMATOR runs under DOS versions 3 to 6, in text mode only.
  972.     It has not been tested with Digital Research DOS (DRDOS), but
  973.     should run OK. It runs under Microsoft Windows 3, ATSR can be
  974.     loaded before running Windows, or can be loaded from the MS-DOS
  975.     window prompt (but is unloaded when MS-DOS is exited).
  976.  
  977.  
  978.     IF THE SCRIPT FILE WON'T RUN CORRECLTY:
  979.  
  980.     This is nearly always caused by invalid code in the script file.
  981.     Ensure that you have inserted sufficient delays with the "W"
  982.     wait command for your application to have finished processing
  983.     before further key depressions are supplied. Some applications
  984.     clear the keyboard buffer after every action, you *must* delay
  985.     script execution until after this point, otherwise keys will
  986.     be lost.
  987.  
  988.     ALOG and ARUN cannot run batch files (.BAT) directly (e.g. DW4),
  989.     see note below.
  990.  
  991.     Some programs which don't chain interrupt handlers correctly,
  992.     or which switch the video "page" may not run properly.
  993.  
  994.  
  995.     SCRIPTS TO INITIALIZE AN APPLICATION:
  996.  
  997.     If all the script file statements are processed (or the script
  998.     contains the "q" quit statement), and the application is still
  999.     running, the application can then be used as normal. This allows
  1000.     script files to be written to automatically carry out any init-
  1001.     ialization operations which would otherwise have to be repeated
  1002.     every time the application was run. To make initialization
  1003.     scripts run as fast as possible, set the delay between keys to
  1004.     the minimum, with a "d0" statement at the start of the script.
  1005.  
  1006.  
  1007.     CREATING LARGE SCRIPT FILES:
  1008.  
  1009.     When creating script files, it is better to produce many small
  1010.     script files, which can be individually tested, then merged into
  1011.     the final file. Use ALOG to produce several script files, then
  1012.     edit and test each one individually. When each is fully tested,
  1013.     remove the unwanted intro and exit scripts then merge them
  1014.     together and run a final complete test. You can also insert "j"
  1015.     jump statements to jump from the start of a script to the part
  1016.     which is being tested, or to jump around untested parts.
  1017.  
  1018.                             ANIDOS - Page 19
  1019.  
  1020.     WAIT STATEMENTS AND PLAYBACK TIMING:
  1021.  
  1022.     When introducing delays with the "w" wait statement, remember
  1023.     that the application will run faster on some machines than on
  1024.     others. Ensure that any delays are adequate for the slowest
  1025.     machine that the package will be run on, e.g. a 4.77MHz PC
  1026.     with floppy disks. If you're using a disk cache, remember that
  1027.     an application will take much longer to load when it is first
  1028.     used, because it's loaded from the disk the first time, and
  1029.     thereafter it's loaded from cache RAM. DOS ANIMATOR's delays
  1030.     will always be the same on every machine, because the machine's
  1031.     real-time clock is used for timing.
  1032.  
  1033.  
  1034.     EXECUTING BATCH (.BAT) FILES WITH ARUN:
  1035.  
  1036.     The application must be a ".EXE" or ".COM" file. ALOG and ARUN
  1037.     cannot execute batch files directly. This is because the DOS
  1038.     command line interpretor (COMMAND.COM) is required to execute
  1039.     a batch file, and COMMAND.COM must be run as if it is the app-
  1040.     lication. To do this, use "ARUN <scriptfile> DOS", and put the
  1041.     key depressions to execute the batch file into the script file.
  1042.     To create a log file, use "ALOG <scriptfile> COMMAND" (run
  1043.     COMMAND.COM as the application), then type the keys to run the
  1044.     batch file. For example, if the script file was named SCRIPT
  1045.     and the batch file was named BATCH, then type these commands
  1046.     to create a log file. Use the DOS "EXIT" command to end.
  1047.  
  1048.         C:\>ALOG SCRIPT COMMAND     Executes COMMAND.COM
  1049.          ....             the DOS shell signs on
  1050.         C:\>BATCH             Run the batch file
  1051.           ....
  1052.         C:\>EXIT             Exits DOS shell, saves the
  1053.                      SCRIPT file
  1054.  
  1055.     To run the SCRIPT file, use:
  1056.  
  1057.         C:\>ARUN SCRIPT COMMAND     Loads COMMAND.COM which
  1058.                      will run the batch file
  1059.  
  1060.     Alternatively, you can use the dummy DOS shell called DOS.COM.
  1061.     If you do this, you can delete the "EXIT" command from the end
  1062.     of the script:
  1063.  
  1064.         C:\>ARUN SCRIPT DOS
  1065.  
  1066.     DOS.COM contains only a "return" instruction, which returns
  1067.     immediately to the existing COMMAND.COM shell, which processes
  1068.     further key depressions. DOS.COM *cannot* be used to create
  1069.     script files using ALOG (e.g. ALOG SCRIPT DOS) because there
  1070.     is no way to "exit" and save the script file, since DOS.COM
  1071.     exits immediately and creates an empty script file.
  1072.  
  1073.                             ANIDOS - Page 20
  1074.  
  1075.     AWAITING COMPLETION OF DOS COMMANDS WHEN ANIMATING DOS:
  1076.  
  1077.     When animating DOS itself using "ARUN x DOS" or "ARUN x COMMAND",
  1078.     the script can be paused until the DOS command or application
  1079.     has been completed and the DOS prompt has been displayed, by
  1080.     putting a NUL character (0) in the script. DOS ignores this
  1081.     character, but does not continue until it has been read from
  1082.     the keyboard buffer. See the example in section 4.9.
  1083.  
  1084.  
  1085.     DELETING UNWANTED FILES CREATED BY THE APPLICATION:
  1086.  
  1087.     If files are created by the application when the script file is
  1088.     run, these may need to be deleted afterwards. The "U" (Unlink)
  1089.     statement can be used to delete these files before ending the
  1090.     script.
  1091.     Alternatively, the ARUN command can be executed from a batch
  1092.     file which can then clean up or delete such files. For example:
  1093.  
  1094.         echo off
  1095.         arun script myprog test.tmp
  1096.         del test.tmp
  1097.  
  1098.  
  1099.     CLEARING POP-UP WINDOWS AND TEXTS:
  1100.  
  1101.     Ensure that any pop-up windows or texts displayed by the script
  1102.     are cleared with the "c" statement before the application scrolls
  1103.     the screen. DOS ANIMATOR doesn't keep track of window positions
  1104.     if the screen is scrolled, and will restore the background to
  1105.     the wrong position on the screen when a "c" statement executes.
  1106.  
  1107.  
  1108.     IF ALOG CREATES AN EMPTY SCRIPT FILE:
  1109.  
  1110.     ALOG cannot create a script file with some programs. This is
  1111.     because these programs steal the same interrupts as ALOG, and do
  1112.     not chain the interrupts correctly, thus preventing ALOG seeing
  1113.     any key depressions. However, manually created script files will
  1114.     work perfectly.
  1115.  
  1116.  
  1117.     SYNCHRONIZATION BETWEEN DOS ANIMATOR AND THE APPLICATION:
  1118.  
  1119.     Before any actions are executed (displaying a pop-up window,
  1120.     changing the state of the shift, alt, ctrl, insert, or lock keys,
  1121.     inputting a key from the user or examining the screen), DOS
  1122.     ANIMATOR waits until all the preceding keys have been processed,
  1123.     thus ensuring that all actions are synchronized.
  1124.  
  1125.  
  1126.     SHIFT, CTRL AND ALT KEY STATES:
  1127.  
  1128.     The "+k" and "-k" statements (section 4.11) affect only the
  1129.     keyboard status flags. The correct ASCII codes or scan codes
  1130.     should be used to represent Ctrl and Alt characters. For example,
  1131.     don't use "+c 'c' -c" for Ctrl+C, instead use 3 (the ASCII code
  1132.     for Ctrl+C is 3), "+c 3 -c" is also valid and may be required by
  1133.     some applications.
  1134.  
  1135.                             ANIDOS - Page 21
  1136.  
  1137.     CTRL+C AND CTRL+BREAK:
  1138.  
  1139.     DOS ANIMATOR does not disable the Ctrl+Break interrupt handler,
  1140.     and does not prevent the keyboard buffer being emptied by DOS.
  1141.     This is because Ctrl+Break or Ctrl+C may be needed in the script
  1142.     file. Some applications exit when Ctrl+C or Ctrl+Break is
  1143.     pressed, and the keyboard buffer is always emptied by DOS, so
  1144.     these key combinations should *not* be pressed while the script
  1145.     is executing.
  1146.  
  1147.  
  1148.     PRESSING CTRL, ALT OR SHIFT WHILE RUNNING THE SCRIPT:
  1149.  
  1150.     On certain less well-behaved applications, pressing Ctrl, Alt,
  1151.     Shift or any of the Lock keys may affect execution of the script.
  1152.     DOS ANIMATOR does not disable these keys.
  1153.  
  1154.                             ANIDOS - Page 22
  1155.  
  1156.     11. APPENDIX
  1157.     ════════════
  1158.  
  1159.     Terms and conditions of use
  1160.     ───────────────────────────
  1161.     You are free to pass copies of the DEMONSTRATION version
  1162.     (ANIDOS.ZIP) to others, providing it is supplied in its original
  1163.     unmodified form, and no fee is charged for the software.
  1164.  
  1165.     Registered users are free to distribute ATSR.COM, ARUN.EXE and
  1166.     DOS.COM to their customers or sales outlets as part of their
  1167.     own packages. Other files may *not* be distributed unless the
  1168.     receiver registers the package with the author.
  1169.  
  1170.     Unregistered use of the package is very naughty, deprives the
  1171.     author of his livelihood, makes it harder for him to pay the
  1172.     mortgage, feed the cat, and continue to provide a service for
  1173.     Britain's flagging industry. So please register your copy now!
  1174.  
  1175.  
  1176.     Standard disclaimer
  1177.     ───────────────────
  1178.     Neither the author nor the distributors of this software make
  1179.     any representations regarding the use, the results of use, the
  1180.     correctness, accuracy, reliability or fitness of this software
  1181.     for any particular purpose, and accept no responsibility for
  1182.     its use or misuse.
  1183.  
  1184.     However, if problems are reported by a registered user, every
  1185.     effort will be made to supply a corrected version as soon as
  1186.     possible.
  1187.  
  1188.  
  1189.     Support
  1190.     ───────
  1191.     Registered users (or potential registered users) can mail me
  1192.     on CompuServe (100015,2546) or CIX (harvey) if they have any
  1193.     questions or problems.
  1194.  
  1195.  
  1196.     Demo version restrictions
  1197.     ─────────────────────────
  1198.     The buffer size is fixed at 5000 bytes. It does not support
  1199.     the "K" (Keyboard), "X" (eXmaine), "S" (Save), "F" (file) or
  1200.     "U" (Unlink) statements.
  1201.  
  1202.                             ANIDOS - Page 23
  1203.  
  1204.     Future enhacements
  1205.     ──────────────────
  1206.     An updated version of this software may be produced if anyone's
  1207.     interested. These features are being considered:
  1208.  
  1209.     -   Unloadable version of ATSR.
  1210.     -   Script buffer in extended memory.
  1211.     -   Keys to pause/continue script execution.
  1212.     -   "Hot key" handling ("h" statement), so that truly embedded
  1213.         macro commands can be added to any existing application.
  1214.         Hitting a hot key executes a subroutine in the script, a
  1215.         script file can contain many "hot key" subroutines.
  1216.     -   Additions for animating software testing, such as comparing
  1217.         actual and expected screens or sections of screens, and
  1218.         logging the differences to a file.
  1219.     -   Include file statement ("i"), so other script files can be
  1220.         included in a main script, e.g. "i fred.ani".
  1221.     -   Log to/playback from serial port, for remote monitoring and
  1222.         control.
  1223.     -   Sound effects, speech, beeps etc.
  1224.     -   Compiler to create binary script files.
  1225.  
  1226.     Further (polite) suggestions welcome.
  1227.  
  1228.  
  1229.     DOS ANIMATOR V1.2 REGISTRATION AND ORDER FORM
  1230.     ═════════════════════════════════════════════
  1231.  
  1232.     (If on CompuServe, use the "Shareware Registration" service).
  1233.  
  1234.  
  1235.     Name:        ___________________________________________________
  1236.  
  1237.     Position:    ___________________________________________________
  1238.  
  1239.     Company:    ___________________________________________________
  1240.  
  1241.     Address:    ___________________________________________________
  1242.  
  1243.     Town/City:    ___________________________________________________
  1244.  
  1245.     County/State:    ______________________     Postcode/Zip: ____________
  1246.  
  1247.     Country:    ___________________________________________________
  1248.  
  1249.     Telephone:    _________________________________________
  1250.  
  1251.  
  1252.  
  1253.     Disk Size:    3.5" (720K)     ____
  1254.  
  1255.             5.25" (360K)    ____
  1256.  
  1257.             5.25" (1.44Mb)  ____
  1258.  
  1259.  
  1260.     Please post me the latest complete version of DOS ANIMATOR.
  1261.     I enclose a registration fee of £25 (includes VAT & P+P)
  1262.     or $35. (Cheques in £s, or US $ money orders, made payable
  1263.     to M.G.Harvey).
  1264.  
  1265.  
  1266.     Signed:     _____________________________
  1267.  
  1268.  
  1269.  
  1270.     Mail the completed form with the registration fee to:
  1271.  
  1272.         Matt Harvey
  1273.         Freelance Development Engineer
  1274.         Studio 9
  1275.         North Street
  1276.         Dorking
  1277.         Surrey RH4 1DN
  1278.         England
  1279.  
  1280.         VAT No:        515 2859 42
  1281.         CIX UK:        harvey
  1282.         CompuServe:     100015,2546
  1283.  
  1284.